namespace Kiwi.Container
{
    public class AddComponentToCacheFailedException : ContainerException
    {
        public AddComponentToCacheFailedException(IComponentRegistration registration)
        {
            Registration = registration;
        }

        public IComponentRegistration Registration { get; private set; }

        public override string Message
        {
            get { return string.Format("Adding component of type {0} to cache failed.", Registration.ComponentType); }
        }
    }
}